package com.zmn.mcc.admin;

import com.zmn.brs.starter.annotation.EnableBusinessRisk;
import com.zmn.framework.web.config.FastJsonHttpMessageConverterConfiguration;
import com.zmn.manager.common.database.config.OneMasterMultiSlaveDataSourceConfiguration;
import com.zmn.manager.mq.annotation.EnableMQSend;
import lombok.extern.slf4j.Slf4j;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.autoconfigure.jdbc.DataSourceAutoConfiguration;
import org.springframework.context.annotation.Import;
import org.springframework.scheduling.annotation.EnableAsync;
import org.springframework.transaction.annotation.EnableTransactionManagement;

/**
 * @author heguanghua
 * @since 2020/04/09 18:42
 */
@EnableAsync
@EnableTransactionManagement
@EnableMQSend
@SpringBootApplication(scanBasePackages = {"com.zmn.mcc", "com.zmn.base.plat.engine.anole"}, exclude = {DataSourceAutoConfiguration.class})
@Import({OneMasterMultiSlaveDataSourceConfiguration.class, FastJsonHttpMessageConverterConfiguration.class})
@Slf4j
@EnableBusinessRisk(tenant = "com.zmn.brs")
public class AdminApplication {


    public static void main(String[] args) {

        try {
            SpringApplication.run(AdminApplication.class, args);
        } catch (Exception ex) {
            log.error("启动失败", ex);
        }
    }


}

